<?php
/**
 * Created by PhpStorm.
 * User: ewen
 * Date: 2019-08-02
 * Time: 16:18
 */

namespace app\common\validate;

use think\Validate;

class System extends Validate
{
    /**
     * 验证规则
     * @var array
     */
    protected $rule = [
        'webName' => 'require|max:20|min:2',
    ];

    /**
     * 验证信息
     * @var array
     */
    protected $message = [
        'webName.require' => '{%webName require}',
        'webName.max' => '{%webName too long}',
        'webName.min' => '{%webName too short}',
    ];

    /**
     * 验证场景
     * @var array
     */
    protected $scene = [
        'editSetting' => ['webName'],
    ];

}